<% include ../common/header.html %>
<link rel="stylesheet" href="/dist/lib/css/summernote.css">

<div class="container bread">
    <a class="btn btn-default" href="/blog">返回首页</a>
    <p>目前位置: <a href="/blog">EUX博客</a>\修改文章</p>
</div>

<div class="container blog-new" data-id="<%= article['_id'] %>">
    <div class="row">
        <div class="col-sm-9">
            <form>
                <div class="form-group">
                    <label for="title">标题</label>
                    <input name="title" maxlength="24" type="text" class="form-control" id="title" placeholder="请输入标题,少于24字" required value="<%= article.title %>">
                </div>
                <div class="form-group">
                    <label for="classify">选择分类</label>
                    <select class="form-control" id="classify" name="classify">
                        <option value="0">前端开发</option>
                        <option value="1">视觉设计</option>
                        <option value="2">交互设计</option>
                        <option value="3">后端开发</option>
                        <option value="4">APP开发</option>
                        <option value="8">其它</option>
                    </select>
                </div>
                <div class="form-group">
                    <label for="tags">添加标签</label>
                    <div class="tag-box">
                    </div>
                    <input type="text" maxlength="8" class="form-control" placeholder="标签少于8个字" id="tags"><a id="add-btn" class="btn btn-default" href="#">+</a>
                </div>
                <div class="form-group">
                    <label for="summernote">正文</label>
                    <div id="summernote"></div>
                </div>
                <button type="submit" class="btn btn-primary submit">保存修改</button>

            </form>
        </div>
    </div>
</div>

<script src="/dist/lib/js/summernote.min.js"></script>
<script src="/dist/lib/js/summernote-zh-CN.js"></script>
<script>
    $('#summernote').summernote({
        height: 300,
        toolbar: [
            ['style', ['style']],
            ['font', ['bold', 'underline', 'clear']],
            ['color', ['color']],
            ['para', ['ul', 'ol', 'paragraph']],
            ['table', ['table']],
            ['insert', ['link', 'picture']],
            ['view', ['fullscreen', 'codeview', 'help']]
        ],
        placeholder: '如要输入代码请打开code视图输入 : <pre><code data-language="javascript(可更换)">你的代码</code></pre>',
        lang: 'zh-CN'
    });
</script>
<script src="/dist/js/blog/edit_article.min.js"></script>

<% include ../common/footer.html %>
